<!--
 * @Description: 学生身份认证审核
 * @Author: along
 * @Date: 2019-08-24
 * @Last Modified by: liyujie
 * @Last Modified time: 2021/08/31
-->
<template>
    <PageLayout
        title="学生身份认证审核"
        class="page-layout-student-verify"
    >
        <template slot="filter">
            <div class="filter-item">
                <div class="filter-item__title">
                    用户信息
                </div>
                <el-input
                    v-model="formData.keyword"
                    placeholder="请输入手机/ID/姓名"
                    size="medium"
                    clearable
                    suffix-icon="el-icon-search"
                    style="width: 224px"
                    @change="getTableData(1)"
                    @keyup.native.enter="getTableData(1)"
                />
            </div>
            <div class="filter-item">
                <div class="filter-item__title">
                    大学名称
                </div>
                <el-cascader
                    placeholder="请选择"
                    :options="school_tree"
                    filterable
                    clearable
                    change-on-select
                    expand-trigger="click"
                    v-model="keyword_school"
                    size="medium"
                    style="width: 152px"
                    @change="getTableData(1)"
                    @keyup.native.enter="getTableData(1)"
                    :props="{
                        label: 'name',
                        value: 'id',
                        children: 'children'
                    }"
                />
            </div>
            <div class="filter-item">
                <div class="filter-item__title">
                    审核状态
                </div>
                <el-select
                    v-model="formData.audit"
                    clearable
                    filterable
                    placeholder="请选择"
                    size="medium"
                    style="width: 152px"
                    @change="getTableData(1)"
                >
                    <el-option
                        v-for="item in auditList"
                        :key="item.value"
                        :label="item.label"
                        :value="item.value"/>
                </el-select>
            </div>
            <div class="filter-item">
                <div class="filter-item__title">
                    审核人
                </div>
                <el-input
                    v-model="formData.aidit_user"
                    placeholder="请输入审核人"
                    size="medium"
                    clearable
                    style="width: 152px"
                    suffix-icon="el-icon-search"
                    @change="getTableData(1)"
                    @keyup.native.enter="getTableData(1)"
                />
            </div>
            <div class="filter-item">
                <div class="filter-item__title">
                    提交时间
                </div>
                <el-date-picker
                    v-model="date"
                    type="datetimerange"
                    :picker-options="pickerOptions()"
                    range-separator="至"
                    start-placeholder="开始日期"
                    end-placeholder="结束日期"
                    :default-time="['00:00:00', '23:59:59']"
                    align="right"
                    size="medium"
                    style="width: 360px"
                    @change="getTableData(1)"
                />
            </div>
            <div class="filter-item">
                <el-button
                    type="primary"
                    size="small"
                    class="query-button"
                    @click="getTableData(1)"
                >
                    查询
                </el-button>
            </div>
        </template>
        <!-- table -->
        <el-table
            :data="tableData"
            height="100%"
            style="width: 100%;"
            class="data-table"
            ref="table"
            v-loading="tableLoading"
        >
            <el-table-column
                type="index"
                width="60"
                fixed="left"
                label="序号"
                align="center"
            />
            <el-table-column
                label="用户信息"
                width="200"
                fixed="left"
                :formatter="emptyFormatter"
            >
                <template slot-scope="scope">
                    <div class="cell-title">{{ scope.row.true_name ? scope.row.true_name : '--' }}</div>
                    <div class="cell-tips">手机号：{{ scope.row.phone }}</div>
                    <div class="cell-tips">用户ID：{{ scope.row.student_no }}</div>
                </template>
            </el-table-column>
            <el-table-column
                prop="real_name"
                label="真实姓名"
                show-overflow-tooltip
                :formatter="emptyFormatter"
                width="110"
            >
                <template slot-scope="scope">
                    {{ scope.row.real_name }}
                    <i
                        class="iconfont el-icon-hand-tanhao3x"
                        style="color: #FF3030"
                        v-if="scope.row.has_same_verify_info"
                    />
                </template>
            </el-table-column>
            <el-table-column
                prop="verify_school_name"
                label="学校信息"
                width="110"
                :formatter="emptyFormatter"
            />
            <el-table-column
                prop="college_name"
                label="学院信息"
                width="110"
                :formatter="emptyFormatter"
            />
            <el-table-column
                label="入学年份/学制/毕业年份"
                show-overflow-tooltip
                width="180"
                align="center"
            >
                <template slot-scope="scope">
                    {{ scope.row.enter_school_year ? `${scope.row.enter_school_year}年` : '--' }} /
                    {{ scope.row.education_year ? `${scope.row.education_year}年制` : '--' }} /
                    {{ scope.row.finish_school_year ? `${scope.row.finish_school_year}年` : '--' }}
                </template>
            </el-table-column>
            <el-table-column
                label="学生证/录取通知书"
                width="140"
                align="center"
            >
                <template slot-scope="scope">
                    <el-image
                        class="table-image"
                        :src="scope.row.student_image"
                        v-if="scope.row.student_image"
                        :preview-src-list="[scope.row.student_image]"
                    />
                    <div v-else>
                        --
                    </div>
                </template>
            </el-table-column>
            <el-table-column
                prop="images"
                label="身份证正面"
                width="110"
                align="center"
            >
                <template slot-scope="scope">
                    <el-image
                        class="table-image"
                        :src="scope.row.id_card_image"
                        v-if="scope.row.id_card_image"
                        :preview-src-list="[scope.row.id_card_image]"
                    />
                    <div v-else>
                        --
                    </div>
                </template>
            </el-table-column>
            <el-table-column
                prop="id_number"
                label="身份证号码"
                width="170"
                :formatter="emptyFormatter"
            />
            <el-table-column
                prop="submit_time"
                label="提交时间"
                show-overflow-tooltip
                :width="150"
            >
                <template slot-scope="scope">
                    {{ scope.row.submit_time * 1000 | dateFormatter('yyyy/MM/dd HH:mm') }}
                </template>
            </el-table-column>
            <el-table-column
                prop="verify"
                label="审核状态"
                show-overflow-tooltip
                :formatter="emptyFormatter"
                align="center"
            >
                <template slot-scope="scope">
                    <div class="status-wrapper">
                        <div
                            :class="['status-dot', scope.row.verify === 1 ? 'success' : scope.row.verify === -1 ? 'danger' : 'warning']"/>
                        <p v-if="scope.row.verify == 1">已通过</p>
                        <p v-if="scope.row.verify == -1">未通过</p>
                        <p v-if="scope.row.verify == 0">待审核</p>
                    </div>
                </template>
            </el-table-column>
            <!--<el-table-column
                prop="verify_time"
                label="审核时间"
                show-overflow-tooltip
                :formatter="emptyFormatter"
                align="center"
                :width="150"
            >
                <template slot-scope="scope">
                    {{ scope.row.verify_time * 1000 | dateFormatter('yyyy/MM/dd HH:mm') }}
                </template>
            </el-table-column>-->
            <el-table-column
                prop="verify_admin_true_name"
                label="审核人"
                show-overflow-tooltip
                :formatter="emptyFormatter"
                align="center"
            />
            <el-table-column
                prop="remark"
                label="备注"
                show-overflow-tooltip
                :formatter="emptyFormatter"
                width="120"
            />
            <el-table-column
                label="操作"
                fixed="right"
                width="164"
            >
                <template slot-scope="scope">
                    <div class="option-btn-group">
                        <el-button
                            type="text"
                            class="curse-add"
                            @click="fnSeeDialog(scope.row, scope.$index)"
                        >
                            {{ scope.row.verify ? '查看' : '审核' }}
                        </el-button>
                        <el-button
                            type="text"
                            @click="fnExamineAdopt(scope.row)"
                            :disabled="scope.row.verify == 0 ? false : true "
                        >
                            通过
                        </el-button>
                        <el-button
                            type="text"
                            @click="confirmVerifyDialog(-1, scope.row)"
                            :disabled="scope.row.verify == 0 ? false : true "
                        >
                            不通过
                        </el-button>
                        <el-button
                            type="text"
                            @click="fnBeizhu(scope.row)"
                        >
                            备注
                        </el-button>
                        <el-button
                            type="text"
                            :disabled="scope.row.verify === 0"
                            @click="fnExamineAgain(scope.row)"
                        >
                            重新审核
                        </el-button>
                    </div>
                </template>
            </el-table-column>
        </el-table>
        <!-- /table -->

        <!-- /分页 -->
        <template slot="pagination">
            <div/>
            <el-pagination
                background
                layout="total, prev, pager, next"
                :current-page.sync="page.now_page"
                :total="page.total_count"
                :page-size="page.page_size"
                @current-change="getTableData"
            />
        </template>
        <!-- 审核弹窗 -->
        <verify-dialog
            title="用户信息"
            :visible.sync="dialogVisible"
            :data="tableData"
            :index="verifyIndex"
            :status="verifyRow.verify === 1 ? 'pass' : verifyRow.verify === -1 ? 'reject' : ''"
            ref="verifyDialog"
            v-if="verifyRow"
            @pass="confirmVerifyDialog(1, verifyRow)"
            @reject="confirmVerifyDialog(-1, verifyRow)"
            @change="changeVerifyData($event)"
        >
            <div class="dialog-content">
                <div class="progress-wrapper">
                    <div class="progress">
                        当前审核进度：<el-progress
                            style="width: 240px"
                            :stroke-width="12"
                            color="#20A0FF"
                            :show-text="false"
                            :percentage="((verifyIndex + 1) / tableData.length) * 100"
                        />
                        <span class="progress-tips">{{ verifyIndex + 1 }} / {{ tableData.length }}</span>
                    </div>
                    <div class="verify-admin">
                        审核人：{{ verifyRow.verify_admin_true_name ? verifyRow.verify_admin_true_name : '--' }}
                    </div>
                </div>
                <div class="verify-view">
                    <div
                        class="result-title"
                        :style="{color: verifyRow.verify === 1 ? '#2FBDB3' : '#F95B56'}"
                    >
                        <template v-if="verifyRow.verify === 1">审核通过</template>
                        <template v-if="verifyRow.verify === -1">审核未通过</template>
                    </div>
                    <div
                        class="verify-reason"
                        v-if="verifyRow.verify === -1 && verifyRow.verify_fail_reason"
                    >
                        未通过原因：{{ verifyRow.verify_fail_reason }}
                    </div>
                </div>
                <div class="form-wrap">
                    <div class="form-item">
                        <div class="form-item__label">真实姓名：</div>
                        <div class="form-item__value">{{ verifyRow.real_name ? verifyRow.real_name : '--' }}</div>
                    </div>
                    <div class="form-item">
                        <div class="form-item__label">身份证号：</div>
                        <div class="form-item__value">{{ verifyRow.id_number ? verifyRow.id_number : '--' }}</div>
                    </div>
                    <div class="form-item">
                        <div class="form-item__label">学校名称：</div>
                        <div class="form-item__value">{{ verifyRow.verify_school_name ? verifyRow.verify_school_name : '--' }}</div>
                    </div>
                    <div class="form-item">
                        <div class="form-item__label">学院名称：</div>
                        <div class="form-item__value">{{ verifyRow.college_name ? verifyRow.college_name : '--' }}</div>
                    </div>
                    <div class="form-item">
                        <div class="form-item__label">入学年份：</div>
                        <div class="form-item__value">{{ verifyRow.enter_school_year ? `${verifyRow.enter_school_year}年` : '--' }}</div>
                    </div>
                    <div class="form-item">
                        <div class="form-item__label">学制：</div>
                        <div class="form-item__value">{{ verifyRow.education_year ? `${verifyRow.education_year}年制` : '--' }}</div>
                    </div>
                    <div class="form-item">
                        <div class="form-item__label">毕业年份：</div>
                        <div class="form-item__value">{{ verifyRow.finish_school_year ? `${verifyRow.finish_school_year}年` : '--' }}</div>
                    </div>
                    <div class="form-item last">
                        <div class="form-item__label">凭证图片：</div>
                        <div class="form-item__content">
                            <div class="image-item">
                                <el-image
                                    class="image-wrapper"
                                    :src="verifyRow.student_image"
                                    v-if="verifyRow.student_image"
                                    :preview-src-list="[verifyRow.student_image]"
                                />
                                <div class="image-tips">学生证/录取通知书</div>
                            </div>
                            <div class="image-item">
                                <el-image
                                    class="image-wrapper"
                                    :src="verifyRow.id_card_image"
                                    v-if="verifyRow.id_card_image"
                                    :preview-src-list="[verifyRow.id_card_image]"
                                />
                                <div class="image-tips">身份证正面</div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </verify-dialog>

        <!-- 备注内容 -->
        <el-dialog
            title="备注内容"
            width="530px"
            custom-class="schedule-dialog"
            :visible.sync="showMask"
        >
            <el-form
                :model="ruleFormMask"
                :rules="rulesMask"
                ref="ruleFormMask"
            >
                <el-form-item
                    prop='reportCont'
                >
                    <el-input
                        type="textarea"
                        :autosize="{ minRows: 2, maxRows: 4}"
                        placeholder="请输入内容"
                        v-model="ruleFormMask.reportCont"
                    />
                </el-form-item>
            </el-form>
            <div
                slot="footer"
                class="dialog-footer"
                :style="{marginTop: '-20px'}"
            >
                <el-button
                    size="small"
                    type="primary"
                    :style="{width: '120px', height: '32px'}"
                    @click="submitForm('ruleFormMask')">提交
                </el-button>
            </div>
        </el-dialog>
        <!-- 备注内容 -->
    </PageLayout>
</template>

<script>
import imgPreview from '@/components/common/img-preview';
import {back} from '@/mixin/back';
import {getDate} from '@/assets/js/utils';
import {mapState} from 'vuex';
import VerifyDialog from "@/components/dialog/verify-dialog";

export default {
    mixins: [back],
    components: {
        VerifyDialog,
        imgPreview
    },
    data() {
        return {
            keyword_school: '',
            change_school_id: '',
            options: {},
            school_name_edit: '',
            school_tree: [],
            dialogVisibleSchool: false,
            student_no: '', //记录编号
            ruleFormMask: {
                reportCont: ''
            },
            rulesMask: {
                reportCont: [
                    {required: true, message: '请填写备注内容', trigger: 'blur'}
                ]
            },
            showMask: false,
            //审核弹窗
            dialogData: {},
            dialog_status: true,
            reason: '',
            pageIndex: 0,
            pageSize: 0,
            dialogVisible: false,
            //筛选字段
            formData: {
                keyword: '',
                audit: 99,
                aidit_user: '',
                date: []
            },
            date: [],
            auditList: [{value: 99, label: '全部'}, {value: 1, label: '通过'}, {value: -1, label: '不通过'}, {
                value: 0,
                label: '未审核'
            }],
            page: {
                now_page: 1,
                total_count: 0,
                page_size: 0
            },
            tableData: [],
            tableLoading: false,
            verifyIndex: 0,
            verifyRow: {},
            authResult: {}
        };
    },
    filters: {},
    computed: {
        ...mapState({
            userInfo: state => state.userinfo.userinfo,
        })
    },
    watch: {
        showMask(val) {
            if (!val) {
                this.$refs['ruleFormMask'].resetFields();
            }
        }
    },
    mounted() {
        this.authResult = this.$route.meta.authResult;
        this.formData.keyword = this.$route.query.student_no ? this.$route.query.student_no : '';
        this.getTableData();
        this.getSchoolTree();
    },
    methods: {
        /**
         * @description 获取表格数据
         */
        getTableData(page) {
            this.tableLoading = true;
            this.$post('/student/student_user_student_verify%5Cget_list', {
                page_id: page || this.page.now_page,
                keyword_student_id: this.formData.keyword,
                verify: this.formData.audit,
                verify_admin_true_name: this.formData.aidit_user,
                submit_start_time: this.date === null ? '' : (this.date.length == 0 ? '' : getDate(new Date(this.date[0]))),
                submit_end_time: this.date === null ? '' : (this.date.length == 0 ? '' : getDate(new Date(this.date[1]))),
                verify_school_id: this.keyword_school.length > 0 ? this.keyword_school[2] : '',
                version: 2
            }, resp => {
                if (resp.code === 1) {
                    this.tableData = resp.data.list;
                    this.page.now_page = resp.data.page.now_page;
                    this.page.total_count = resp.data.page.total_count;
                    this.page.page_size = resp.data.page.page_size;

                    //计算当前页数据数量
                    if (resp.data.page.total_count == 1) {
                        this.pageSize = resp.data.page.total_count;
                    } else if (resp.data.page.total_count > 1 && resp.data.page.next_page > 0) {
                        this.pageSize = 20;
                    } else if (resp.data.page.total_count > 1 && resp.data.page.next_page == 0) {
                        this.pageSize = resp.data.page.total_count - (resp.data.page.now_page - 1) * 20;
                    }
                    this.verifyRow = this.tableData[this.verifyIndex];
                }
                this.tableLoading = false;
            });
        },

        /**
         * @description 获取省/市/学校三级联动
         */
        getSchoolTree() {
            this.$post('/student/local_info%5Cschool_tree', {}, resp => {
                if (resp.code == 1) {
                    this.school_tree = resp.data.tree;
                }
            });
        },

        /**
         * @description 查看
         */
        fnSeeDialog(row, index) {
            this.verifyIndex = index;
            this.verifyRow = row;
            this.dialogVisible = true;
        },

        /**
         * @description 审核通过
         */
        fnExamineAdopt(row) {
            if (!this.authResult.auth_verfy) {
                this.$notify({
                    title: '提示',
                    message: '此权限仅限管理员',
                    type: 'warning',
                    duration: 2000
                });
                return;
            }

            this.$zdConfirm('是否确定通过审核？', '温馨提示', {
                confirmButtonText: '确定',
                cancelButtonText: '取消',
                type: 'warning'
            }).then(() => {
                this.$post('/student/student_user_student_verify%5Cverify', {
                    student_no: row.student_no,
                    verify: 1,
                    change_school_id: this.change_school_id
                }, resp => {
                    if (resp.code == 1) {
                        this.getTableData();
                        this.dialog_status = false;
                        this.change_school_id = '';
                        this.dialogData = this.tableData[this.pageIndex];
                        this.$set(this.dialogData, 'verify', 1);
                        this.$notify({
                            title: '提示',
                            message: '操作成功',
                            type: 'success',
                            duration: 2000
                        });
                    } else {
                        this.$notify({
                            title: '提示',
                            message: resp.msg,
                            type: 'warning',
                            duration: 2000
                        });
                    }
                });
            }).catch(() => {});
        },

        /**
         * @description 重新审核
         */
        fnExamineAgain(row) {
            if (!this.authResult.auth_verify_again) {
                this.$notify({
                    title: '提示',
                    message: '此权限仅限管理员',
                    type: 'warning',
                    duration: 2000
                });
                return;
            }

            this.$zdConfirm('是否确定重新审核？', '温馨提示', {
                confirmButtonText: '确定',
                cancelButtonText: '取消',
                type: 'warning'
            }).then(() => {
                this.$post('/student/student_user_student_verify%5Creset', {
                    student_no: row.student_no
                }, resp => {
                    if (resp.code === 1) {
                        this.getTableData();
                        this.$notify({
                            title: '提示',
                            message: '操作成功',
                            type: 'success',
                            duration: 2000
                        });
                    } else {
                        this.$notify({
                            title: '提示',
                            message: resp.msg,
                            type: 'warning',
                            duration: 2000
                        });
                    }
                });
            }).catch(() => {});
        },

        /**
         * @description 审核不通过
         */
        fnExamineNoAdopt(row, type) {
            if (!this.authResult.auth_verfy) {
                this.$notify({
                    title: '提示',
                    message: '此权限仅限管理员',
                    type: 'warning',
                    duration: 2000
                });
                return;
            }

            if (type) {
                this.$prompt('请输入不通过原因', '提示', {
                    confirmButtonText: '确定',
                    cancelButtonText: '取消',
                    inputPattern: /\S/,
                    inputErrorMessage: '内容不可以为空'
                }).then(({value}) => {
                    this.$post('/student/student_user_student_verify%5Cverify', {
                        student_no: row.student_no,
                        verify: -1,
                        verify_fail_reason: value
                    }, resp => {
                        if (resp.code == 1) {
                            this.getTableData();
                            this.dialog_status = false;
                            this.$notify({
                                title: '提示',
                                message: '操作成功',
                                type: 'success',
                                duration: 2000
                            });
                            this.change_school_id = '';
                        } else {
                            this.$notify({
                                title: '提示',
                                message: resp.msg,
                                type: 'warning',
                                duration: 2000
                            });
                        }
                    });
                });
            }

            if (!type) {
                if (this.reason == '') {
                    this.$message({
                        type: 'waring',
                        message: '请填写不通过理由,不可以为空',
                        center: true
                    });
                    return;
                } else {
                    this.$post('/student/student_user_student_verify%5Cverify', {
                        student_no: this.dialogData.student_no,
                        verify: -1,
                        verify_fail_reason: this.reason,
                        change_school_id: this.change_school_id
                    }, resp => {
                        if (resp.code == 1) {
                            this.getTableData();
                            this.dialog_status = false;
                            this.dialogData = this.tableData[this.pageIndex];
                            this.$set(this.dialogData, 'verify', -1);
                            this.change_school_id = '';
                            this.$notify({
                                title: '提示',
                                message: '操作成功',
                                type: 'success',
                                duration: 2000
                            });
                        } else {
                            this.$notify({
                                title: '提示',
                                message: resp.msg,
                                type: 'warning',
                                duration: 2000
                            });
                        }
                    });
                }
            }
        },

        /**
         * @description 打开备注弹窗
         */
        fnBeizhu(row) {
            this.student_no = row.student_no;
            this.showMask = !this.showMask;
        },

        /**
         * @description 提交备注
         */
        submitForm(formName) {
            this.$refs[formName].validate((valid) => {
                if (valid) {
                    this.$post('/student/student_user_student_verify%5Cremark', {
                        student_no: this.student_no,
                        remark: this.ruleFormMask.reportCont
                    }, resp => {
                        if (resp.code == 1) {
                            this.getTableData();
                            this.showMask = !this.showMask;
                            this.$notify({
                                title: '提示',
                                message: '操作成功',
                                type: 'success',
                                duration: 2000
                            });
                        } else if (resp.code == 0) {
                            this.$notify({
                                title: '提示',
                                message: resp.msg,
                                type: 'warning',
                                duration: 2000
                            });
                        }
                    });
                } else {
                    console.log('error submit!!');
                    return false;
                }
            });
        },

        /**
         * @description 时间处理
         */
        pickerOptions() {
            return {
                shortcuts: [{
                    text: '最近一周',
                    onClick(picker) {
                        const end = new Date();
                        const start = new Date();

                        start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
                        picker.$emit('pick', [start, end]);
                    }
                }, {
                    text: '最近一个月',
                    onClick(picker) {
                        const end = new Date();
                        const start = new Date();

                        start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
                        picker.$emit('pick', [start, end]);
                    }
                }, {
                    text: '最近三个月',
                    onClick(picker) {
                        const end = new Date();
                        const start = new Date();

                        start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
                        picker.$emit('pick', [start, end]);
                    }
                }]
            };
        },

        /**
         * @description 过滤函数
         */
        emptyFormatter(row, column, val) {
            if (!val) return '--';
            return val;
        },

        /**
         * 上一条或下一条
         * @param type - next下一步 prev上一步
         */
        changeVerifyData(type) {
            if (type === 'next' && this.verifyIndex < this.tableData.length - 1) {
                this.verifyIndex++;
                this.verifyRow = this.tableData[this.verifyIndex];
            }
            if (type === 'prev' && this.verifyIndex > 0) {
                this.verifyIndex--;
                this.verifyRow = this.tableData[this.verifyIndex];
            }
        },

        /**
         * 显示审核操作弹窗
         * @param action -1拒绝 1 通过
         * @param row
         */
        async confirmVerifyDialog(action, row) {
            // 通过
            if (action === 1) {
                this.$zdConfirm('是否确定通过审核？', '温馨提示', {
                    confirmButtonText: '确定',
                    cancelButtonText: '取消',
                    type: 'warning'
                }).then(() => {
                    this.handleVerify(row.student_no, action);
                });
            } else {
                let reason = await this.$zdPrompt({
                    title: '审核驳回',
                    message: '不通过原因',
                    placeholder: '请输入不通过的原因...',
                });

                if(reason) {
                    this.handleVerify(row.student_no, action, reason);
                }
            }
        },

        /**
         * 审核
         * @param student_no
         * @param verify
         * @param verify_fail_reason
         */
        handleVerify(student_no, verify, verify_fail_reason) {
            let params = {
                student_no,
                verify,
                verify_fail_reason
            };

            this.$post('/student/student_user_student_verify%5Cverify', params, resp => {
                if (resp.code === 1) {
                    this.$notify({
                        title: '提示',
                        message: '操作成功',
                        duration: 2000,
                        type: 'success'
                    });
                    this.getTableData();
                } else {
                    this.$notify({
                        title: '提示',
                        message: resp.msg,
                        duration: 2000,
                        type: 'warning'
                    });
                }
            });
        },
    }
};
</script>

<style lang="less" scoped>
.page-layout-student-verify {
    flex: 1;
    /deep/ .content-wrapper {
        margin: 0!important;
        height: 100%!important;
        .header {
            display: none;
        }
    }
}
.table-wrapper {
    .table-image {
        width: 70px;
        height: 70px;
        cursor: pointer;
        /deep/ .el-image__inner  {
            object-fit: cover;
        }
    }
}

.dialog-footer {
    display: flex;
    justify-content: center;
}
.dialog-content {
    margin-bottom: 24px;
    .progress-wrapper {
        display: flex;
        align-items: center;
        justify-content: space-between;
        .progress {
            display: flex;
            align-items: center;
            font-size: 14px;
            font-family: PingFangSC-Regular, PingFang SC;
            font-weight: 400;
            color: #666666;
        }
        /deep/ .el-progress-bar__outer {
            background: #DFEBFF;
        }
        .progress-tips {
            font-size: 14px;
            font-family: PingFangSC-Regular, PingFang SC;
            font-weight: 400;
            color: #20A0FF;
            margin-left: 12px;
        }
    }
    .verify-admin {
        font-size: 14px;
        font-family: PingFangSC-Regular, PingFang SC;
        font-weight: 400;
        color: #666666;
    }
    .verify-view {
        margin-top: 24px;
        .result-title {
            font-size: 16px;
            font-family: PingFangSC-Medium, PingFang SC;
            font-weight: 500;
            margin-bottom: 12px;
        }
        .verify-reason {
            font-size: 14px;
            font-family: PingFangSC-Regular, PingFang SC;
            font-weight: 400;
            color: #999999;
            margin-bottom: 12px;
        }
    }
    .form-wrap {
        display: flex;
        flex-wrap: wrap;
        margin-top: 24px;
        .form-item {
            display: flex;
            align-items: center;
            font-size: 14px;
            font-family: PingFangSC-Regular, PingFang SC;
            font-weight: 400;
            margin-bottom: 24px;
            width: 50%;
            &__label {
                color: #888888;
            }
            &__value {
                color: #333333;
            }
            &.last {
                width: 100%;
                align-items: flex-start;
            }
            &__content {
                display: flex;
                .image-item {
                    border-radius: 4px;
                    margin-right: 12px;
                    display: flex;
                    flex-direction: column;
                    align-items: center;
                    .image-tips {
                        font-size: 12px;
                        font-family: PingFangSC-Regular, PingFang SC;
                        font-weight: 400;
                        color: #888888;
                        margin-top: 12px;
                    }
                    .image-wrapper {
                        width: 160px;
                        height: 90px;
                        cursor: pointer;
                        border: 1px solid #F1F1F1;
                        /deep/ .el-image__inner  {
                            object-fit: cover;
                        }
                    }
                }
            }
        }
    }
}

/deep/ .el-icon-circle-close {
    color: #fff;
}
/deep/ .result-view {
    display: none;
}
</style>
